Optimal. Leaf size=53 \[ \frac {b \text {ArcTan}\left (\frac {\sqrt {a+b} \sinh (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} (a+b)^{3/2} d}+\frac {\sinh (c+d x)}{(a+b) d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.05, antiderivative size = 53, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 3, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3757, 396, 211}
\begin {gather*} \frac {b \text {ArcTan}\left (\frac {\sqrt {a+b} \sinh (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} d (a+b)^{3/2}}+\frac {\sinh (c+d x)}{d (a+b)} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 211
Rule 396
Rule 3757
Rubi steps
\begin {align*} \int \frac {\cosh (c+d x)}{a+b \tanh ^2(c+d x)} \, dx &=\frac {\text {Subst}\left (\int \frac {1+x^2}{a+(a+b) x^2} \, dx,x,\sinh (c+d x)\right )}{d}\\ &=\frac {\sinh (c+d x)}{(a+b) d}+\frac {b \text {Subst}\left (\int \frac {1}{a+(a+b) x^2} \, dx,x,\sinh (c+d x)\right )}{(a+b) d}\\ &=\frac {b \tan ^{-1}\left (\frac {\sqrt {a+b} \sinh (c+d x)}{\sqrt {a}}\right )}{\sqrt {a} (a+b)^{3/2} d}+\frac {\sinh (c+d x)}{(a+b) d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.16, size = 54, normalized size = 1.02 \begin {gather*} -\frac {b \text {ArcTan}\left (\frac {\sqrt {a} \text {csch}(c+d x)}{\sqrt {a+b}}\right )}{\sqrt {a} (a+b)^{3/2} d}+\frac {\sinh (c+d x)}{(a+b) d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(207\) vs.
\(2(45)=90\).
time = 2.68, size = 208, normalized size = 3.92
method | result | size |
risch | \(\frac {{\mathrm e}^{d x +c}}{2 \left (a +b \right ) d}-\frac {{\mathrm e}^{-d x -c}}{2 \left (a +b \right ) d}-\frac {b \ln \left ({\mathrm e}^{2 d x +2 c}-\frac {2 a \,{\mathrm e}^{d x +c}}{\sqrt {-a^{2}-a b}}-1\right )}{2 \sqrt {-a^{2}-a b}\, \left (a +b \right ) d}+\frac {b \ln \left ({\mathrm e}^{2 d x +2 c}+\frac {2 a \,{\mathrm e}^{d x +c}}{\sqrt {-a^{2}-a b}}-1\right )}{2 \sqrt {-a^{2}-a b}\, \left (a +b \right ) d}\) | \(149\) |
derivativedivides | \(\frac {-\frac {2}{\left (2 b +2 a \right ) \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}+\frac {2 b a \left (-\frac {\left (\sqrt {b \left (a +b \right )}-b \right ) \arctanh \left (\frac {a \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {\left (2 \sqrt {b \left (a +b \right )}-a -2 b \right ) a}}\right )}{2 a \sqrt {b \left (a +b \right )}\, \sqrt {\left (2 \sqrt {b \left (a +b \right )}-a -2 b \right ) a}}+\frac {\left (\sqrt {b \left (a +b \right )}+b \right ) \arctan \left (\frac {a \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {\left (2 \sqrt {b \left (a +b \right )}+a +2 b \right ) a}}\right )}{2 a \sqrt {b \left (a +b \right )}\, \sqrt {\left (2 \sqrt {b \left (a +b \right )}+a +2 b \right ) a}}\right )}{a +b}-\frac {2}{\left (2 b +2 a \right ) \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}}{d}\) | \(208\) |
default | \(\frac {-\frac {2}{\left (2 b +2 a \right ) \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}+\frac {2 b a \left (-\frac {\left (\sqrt {b \left (a +b \right )}-b \right ) \arctanh \left (\frac {a \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {\left (2 \sqrt {b \left (a +b \right )}-a -2 b \right ) a}}\right )}{2 a \sqrt {b \left (a +b \right )}\, \sqrt {\left (2 \sqrt {b \left (a +b \right )}-a -2 b \right ) a}}+\frac {\left (\sqrt {b \left (a +b \right )}+b \right ) \arctan \left (\frac {a \tanh \left (\frac {d x}{2}+\frac {c}{2}\right )}{\sqrt {\left (2 \sqrt {b \left (a +b \right )}+a +2 b \right ) a}}\right )}{2 a \sqrt {b \left (a +b \right )}\, \sqrt {\left (2 \sqrt {b \left (a +b \right )}+a +2 b \right ) a}}\right )}{a +b}-\frac {2}{\left (2 b +2 a \right ) \left (\tanh \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}}{d}\) | \(208\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 295 vs.
\(2 (45) = 90\).
time = 0.39, size = 766, normalized size = 14.45 \begin {gather*} \left [\frac {{\left (a^{2} + a b\right )} \cosh \left (d x + c\right )^{2} + 2 \, {\left (a^{2} + a b\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right ) + {\left (a^{2} + a b\right )} \sinh \left (d x + c\right )^{2} - \sqrt {-a^{2} - a b} {\left (b \cosh \left (d x + c\right ) + b \sinh \left (d x + c\right )\right )} \log \left (\frac {{\left (a + b\right )} \cosh \left (d x + c\right )^{4} + 4 \, {\left (a + b\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{3} + {\left (a + b\right )} \sinh \left (d x + c\right )^{4} - 2 \, {\left (3 \, a + b\right )} \cosh \left (d x + c\right )^{2} + 2 \, {\left (3 \, {\left (a + b\right )} \cosh \left (d x + c\right )^{2} - 3 \, a - b\right )} \sinh \left (d x + c\right )^{2} + 4 \, {\left ({\left (a + b\right )} \cosh \left (d x + c\right )^{3} - {\left (3 \, a + b\right )} \cosh \left (d x + c\right )\right )} \sinh \left (d x + c\right ) - 4 \, {\left (\cosh \left (d x + c\right )^{3} + 3 \, \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{2} + \sinh \left (d x + c\right )^{3} + {\left (3 \, \cosh \left (d x + c\right )^{2} - 1\right )} \sinh \left (d x + c\right ) - \cosh \left (d x + c\right )\right )} \sqrt {-a^{2} - a b} + a + b}{{\left (a + b\right )} \cosh \left (d x + c\right )^{4} + 4 \, {\left (a + b\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{3} + {\left (a + b\right )} \sinh \left (d x + c\right )^{4} + 2 \, {\left (a - b\right )} \cosh \left (d x + c\right )^{2} + 2 \, {\left (3 \, {\left (a + b\right )} \cosh \left (d x + c\right )^{2} + a - b\right )} \sinh \left (d x + c\right )^{2} + 4 \, {\left ({\left (a + b\right )} \cosh \left (d x + c\right )^{3} + {\left (a - b\right )} \cosh \left (d x + c\right )\right )} \sinh \left (d x + c\right ) + a + b}\right ) - a^{2} - a b}{2 \, {\left ({\left (a^{3} + 2 \, a^{2} b + a b^{2}\right )} d \cosh \left (d x + c\right ) + {\left (a^{3} + 2 \, a^{2} b + a b^{2}\right )} d \sinh \left (d x + c\right )\right )}}, \frac {{\left (a^{2} + a b\right )} \cosh \left (d x + c\right )^{2} + 2 \, {\left (a^{2} + a b\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right ) + {\left (a^{2} + a b\right )} \sinh \left (d x + c\right )^{2} + 2 \, \sqrt {a^{2} + a b} {\left (b \cosh \left (d x + c\right ) + b \sinh \left (d x + c\right )\right )} \arctan \left (\frac {{\left (a + b\right )} \cosh \left (d x + c\right )^{3} + 3 \, {\left (a + b\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{2} + {\left (a + b\right )} \sinh \left (d x + c\right )^{3} + {\left (3 \, a - b\right )} \cosh \left (d x + c\right ) + {\left (3 \, {\left (a + b\right )} \cosh \left (d x + c\right )^{2} + 3 \, a - b\right )} \sinh \left (d x + c\right )}{2 \, \sqrt {a^{2} + a b}}\right ) + 2 \, \sqrt {a^{2} + a b} {\left (b \cosh \left (d x + c\right ) + b \sinh \left (d x + c\right )\right )} \arctan \left (\frac {\sqrt {a^{2} + a b} {\left (\cosh \left (d x + c\right ) + \sinh \left (d x + c\right )\right )}}{2 \, a}\right ) - a^{2} - a b}{2 \, {\left ({\left (a^{3} + 2 \, a^{2} b + a b^{2}\right )} d \cosh \left (d x + c\right ) + {\left (a^{3} + 2 \, a^{2} b + a b^{2}\right )} d \sinh \left (d x + c\right )\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\cosh {\left (c + d x \right )}}{a + b \tanh ^{2}{\left (c + d x \right )}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.68, size = 154, normalized size = 2.91 \begin {gather*} \frac {{\mathrm {e}}^{c+d\,x}}{2\,d\,\left (a+b\right )}-\frac {{\mathrm {e}}^{-c-d\,x}}{2\,d\,\left (a+b\right )}-\frac {b\,\ln \left (\sqrt {-a}\,\sqrt {a+b}+2\,a\,{\mathrm {e}}^{c+d\,x}-\sqrt {-a}\,{\mathrm {e}}^{2\,c+2\,d\,x}\,\sqrt {a+b}\right )}{2\,\sqrt {-a}\,d\,{\left (a+b\right )}^{3/2}}+\frac {b\,\ln \left (2\,a\,{\mathrm {e}}^{c+d\,x}-\sqrt {-a}\,\sqrt {a+b}+\sqrt {-a}\,{\mathrm {e}}^{2\,c+2\,d\,x}\,\sqrt {a+b}\right )}{2\,\sqrt {-a}\,d\,{\left (a+b\right )}^{3/2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________